/*
 * def.h
 *
 *  Created on: 2016-2-27
 *      Author: ZhangXiyin
 */

#ifndef EYAS_SOURCES_IO_CONF_DEF_H_
#define EYAS_SOURCES_IO_CONF_DEF_H_
#include <boost/shared_ptr.hpp>
#include <boost/system/error_code.hpp>
#include <boost/thread/detail/move.hpp>
#include "basic/basic.h"
#include "gc/gc.h"

#define EYAS_IO_RV_REF(TYPE) BOOST_THREAD_RV_REF(TYPE)

namespace eyas {
namespace io {

class tcp_socket;
typedef boost::shared_ptr<tcp_socket> tcp_socket_ptr;

class tcp_client;
typedef boost::shared_ptr<tcp_client> tcp_client_ptr;
class tcp_server;
typedef boost::shared_ptr<tcp_server> tcp_server_ptr;

class connection_base;
typedef boost::shared_ptr<connection_base> connection_ptr;
class tcp_connection;
typedef boost::shared_ptr<tcp_connection> tcp_connection_ptr;


class connection_handler_base;
typedef boost::shared_ptr<connection_handler_base> connection_handler_ptr;

class data_handler_base;
typedef boost::shared_ptr<data_handler_base> data_handler_ptr;

class packet_decoder_base;
typedef boost::shared_ptr<packet_decoder_base> packet_decoder_ptr;

class packet_encoder_base;
typedef boost::shared_ptr<packet_encoder_base> packet_encoder_ptr;

class packet_factory_base;
typedef boost::shared_ptr<packet_factory_base> packet_factory_ptr;

//class writer_base;
//typedef eyas::gc::fast_shared_ptr<writer_base> writer_ptr;

typedef boost::system::error_code error_code;
}
}


#endif /* EYAS_SOURCES_IO_CONF_DEF_H_ */
